-
Notifications
You must be signed in to change notification settings - Fork 9
Fix vm disk remove #252
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix vm disk remove #252
Conversation
0ca1640 to
4988468
Compare
|
Integ test: Edit: in 5479912287 failed vm_clone, looks like a bug. A failed virtual_disk_attach is likely not a bug in collection (but in test). |
shoriminimoe
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm still learning Ansible testing so this may be an ignorant question. Are the new vm__* and vm_disk__* tests not the same thing? What is the difference?
58b7aa4 to
6f3a752
Compare
They are very similar, and both modules use same code from module_utils. But they are not exactly the same, so I added separate tests (and after doing this, I noticed vm_disk module does not correctly restart VMs). |
6f3a752 to
a760aa7
Compare
Signed-off-by: Justin Cinkelj <justin.cinkelj@xlab.si>
a760aa7 to
8e92668
Compare
PolonaM
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Justin for the work! Except for the mentioned replacement of task_tag with task_status and maybe even adding the task status to typed_classes.py, everything else looks good to me.
Before VM was (always) shutdown only if IDE CD-ROM was removed. Now VM will be shutdown if disk removal from running VM fails. Fixes #249 Signed-off-by: Justin Cinkelj <justin.cinkelj@xlab.si>
Flag .needs_reboot was set on one object, but vm_power_up() was called on different object, so VM was not started back. Signed-off-by: Justin Cinkelj <justin.cinkelj@xlab.si>
Signed-off-by: Justin Cinkelj <justin.cinkelj@xlab.si>
31fc75f to
e5297aa
Compare
Sometimes we can remove disk from a running VM, and sometimes we need to shutdown VM before disk can be removed. It depends on HyperCore thinking VM might be using the disk.
The PR:
Integration tests for all this is included, for
vmandvm_diskmodules. It covers 3 cases:A small bug in vm_disk module was also fixed. The module didn't start back VM if it was shutdown during execution.